package com.example.company.service.impl;


import com.example.company.entity.Employees;
import com.example.company.mapper.EmployeesMapper;
import com.example.company.service.IEmployeesService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 存储员工基本信息Service业务层处理
 *
 * @author ruoyi
 * @date 2024-12-30
 */
@Service
public class EmployeesServiceImpl implements IEmployeesService {
	@Autowired
	private EmployeesMapper employeesMapper;
	
	/**
	 * 查询存储员工基本信息
	 *
	 * @param EmployeeID 存储员工基本信息主键
	 * @return 存储员工基本信息
	 */
	@Override
	public Employees selectEmployeesByEmployeeID(Long EmployeeID) {
		return employeesMapper.selectEmployeesByEmployeeID(EmployeeID);
	}
	
	/**
	 * 查询存储员工基本信息列表
	 *
	 * @param employees 存储员工基本信息
	 * @return 存储员工基本信息
	 */
	@Override
	public List<Employees> selectEmployeesList(Employees employees) {
		return employeesMapper.selectEmployeesList(employees);
	}
	
	/**
	 * 新增存储员工基本信息
	 *
	 * @param employees 存储员工基本信息
	 * @return 结果
	 */
	@Override
	public int insertEmployees(Employees employees) {
		return employeesMapper.insertEmployees(employees);
	}
	
	/**
	 * 修改存储员工基本信息
	 *
	 * @param employees 存储员工基本信息
	 * @return 结果
	 */
	@Override
	public int updateEmployees(Employees employees) {
		return employeesMapper.updateEmployees(employees);
	}
	
	/**
	 * 批量删除存储员工基本信息
	 *
	 * @param EmployeeIDs 需要删除的存储员工基本信息主键
	 * @return 结果
	 */
	@Override
	public int deleteEmployeesByEmployeeIDs(Long[] EmployeeIDs) {
		return employeesMapper.deleteEmployeesByEmployeeIDs(EmployeeIDs);
	}
	
	/**
	 * 删除存储员工基本信息信息
	 *
	 * @param EmployeeID 存储员工基本信息主键
	 * @return 结果
	 */
	@Override
	public int deleteEmployeesByEmployeeID(Long EmployeeID) {
		return employeesMapper.deleteEmployeesByEmployeeID(EmployeeID);
	}
}
